package com.zshan.clinic.database.model;

import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDate;
import java.util.Date;

/**
 * 发药单
 */
public class OrderDelivery implements Serializable {
    /** 发药单ID;发药单ID */
    private Long orderId;

    /** 诊号;唯一诊号 */
    private String visitNo;

    /** 就诊日期 */
    private LocalDate visitDate;

    /** 发药单号 */
    private String orderNo;

    /** 发药状态;待审核，审核通过，审核拒绝 */
    private String deliveryStatus;

    /** 发药数量 */
    private Integer totalDeliveryQty;

    /** 诊断医生ID */
    private Long doctorId;

    /** 诊断医生名 */
    private String doctorName;

    /** 诊断科室ID */
    private Long deptId;

    /** 诊断科室名 */
    private String deptName;

    /** 最终诊断 */
    private String diagnosis;

    /** 诊断时间 */
    private Date diagnosisTime;

    /** 患者ID */
    private Long patientId;

    /** 患者名 */
    private String patientName;

    /** 患者性别;1男生2女生3未知 */
    private String patientGender;

    /** 患者电话 */
    private String patientPhone;

    /** 身份证号 */
    private String idCard;

    /** 年龄年;5代表5岁 */
    private Integer ageYear;

    /** 年龄月;2代表2个月 */
    private Integer ageMonth;

    /** 阳历生日;阳历生日 */
    private LocalDate solarBirthday;

    /** 阴历生日;阴历生日 */
    private LocalDate lunarBirthday;

    /** 体重;53.8kg */
    private BigDecimal weight;

    /** 收缩压;120mmHg */
    private Integer systolicBp;

    /** 舒张压;80mmHg */
    private Integer diastolicBp;

    /** 配药人ID */
    private Long dispenseUserId;

    /** 配药人姓名 */
    private String dispenseUserName;

    /** 配药时间 */
    private Date dispenseTime;

    /** 发药人 */
    private Long deliveryUserId;

    /** 发药人姓名 */
    private String deliveryUserName;

    /** 发药人时间 */
    private Date deliveryTime;

    /** 拒绝原因 */
    private String refuseReason;

    /** 配药单ID */
    private Long dispenseOrderId;

    /** 排序号 */
    private Integer sortNum;

    /** 诊所ID */
    private Long clinicId;

    /** 启用状态;启用状态 */
    private String isEnabled;

    /** 删除标识 */
    private String isDelete;

    /** 创建人ID */
    private Long createUserId;

    /** 创建人 */
    private String createBy;

    /** 创建时间 */
    private Date createTime;

    /** 更新人ID */
    private Long updateUserId;

    /** 更新人 */
    private String updateBy;

    /** 更新时间 */
    private Date updateTime;

    private static final long serialVersionUID = 1L;

    public Long getOrderId() {
        return orderId;
    }

    public void setOrderId(Long orderId) {
        this.orderId = orderId;
    }

    public String getVisitNo() {
        return visitNo;
    }

    public void setVisitNo(String visitNo) {
        this.visitNo = visitNo == null ? null : visitNo.trim();
    }

    public LocalDate getVisitDate() {
        return visitDate;
    }

    public void setVisitDate(LocalDate visitDate) {
        this.visitDate = visitDate;
    }

    public String getOrderNo() {
        return orderNo;
    }

    public void setOrderNo(String orderNo) {
        this.orderNo = orderNo == null ? null : orderNo.trim();
    }

    public String getDeliveryStatus() {
        return deliveryStatus;
    }

    public void setDeliveryStatus(String deliveryStatus) {
        this.deliveryStatus = deliveryStatus == null ? null : deliveryStatus.trim();
    }

    public Integer getTotalDeliveryQty() {
        return totalDeliveryQty;
    }

    public void setTotalDeliveryQty(Integer totalDeliveryQty) {
        this.totalDeliveryQty = totalDeliveryQty;
    }

    public Long getDoctorId() {
        return doctorId;
    }

    public void setDoctorId(Long doctorId) {
        this.doctorId = doctorId;
    }

    public String getDoctorName() {
        return doctorName;
    }

    public void setDoctorName(String doctorName) {
        this.doctorName = doctorName == null ? null : doctorName.trim();
    }

    public Long getDeptId() {
        return deptId;
    }

    public void setDeptId(Long deptId) {
        this.deptId = deptId;
    }

    public String getDeptName() {
        return deptName;
    }

    public void setDeptName(String deptName) {
        this.deptName = deptName == null ? null : deptName.trim();
    }

    public String getDiagnosis() {
        return diagnosis;
    }

    public void setDiagnosis(String diagnosis) {
        this.diagnosis = diagnosis == null ? null : diagnosis.trim();
    }

    public Date getDiagnosisTime() {
        return diagnosisTime;
    }

    public void setDiagnosisTime(Date diagnosisTime) {
        this.diagnosisTime = diagnosisTime;
    }

    public Long getPatientId() {
        return patientId;
    }

    public void setPatientId(Long patientId) {
        this.patientId = patientId;
    }

    public String getPatientName() {
        return patientName;
    }

    public void setPatientName(String patientName) {
        this.patientName = patientName == null ? null : patientName.trim();
    }

    public String getPatientGender() {
        return patientGender;
    }

    public void setPatientGender(String patientGender) {
        this.patientGender = patientGender == null ? null : patientGender.trim();
    }

    public String getPatientPhone() {
        return patientPhone;
    }

    public void setPatientPhone(String patientPhone) {
        this.patientPhone = patientPhone == null ? null : patientPhone.trim();
    }

    public String getIdCard() {
        return idCard;
    }

    public void setIdCard(String idCard) {
        this.idCard = idCard == null ? null : idCard.trim();
    }

    public Integer getAgeYear() {
        return ageYear;
    }

    public void setAgeYear(Integer ageYear) {
        this.ageYear = ageYear;
    }

    public Integer getAgeMonth() {
        return ageMonth;
    }

    public void setAgeMonth(Integer ageMonth) {
        this.ageMonth = ageMonth;
    }

    public LocalDate getSolarBirthday() {
        return solarBirthday;
    }

    public void setSolarBirthday(LocalDate solarBirthday) {
        this.solarBirthday = solarBirthday;
    }

    public LocalDate getLunarBirthday() {
        return lunarBirthday;
    }

    public void setLunarBirthday(LocalDate lunarBirthday) {
        this.lunarBirthday = lunarBirthday;
    }

    public BigDecimal getWeight() {
        return weight;
    }

    public void setWeight(BigDecimal weight) {
        this.weight = weight;
    }

    public Integer getSystolicBp() {
        return systolicBp;
    }

    public void setSystolicBp(Integer systolicBp) {
        this.systolicBp = systolicBp;
    }

    public Integer getDiastolicBp() {
        return diastolicBp;
    }

    public void setDiastolicBp(Integer diastolicBp) {
        this.diastolicBp = diastolicBp;
    }

    public Long getDispenseUserId() {
        return dispenseUserId;
    }

    public void setDispenseUserId(Long dispenseUserId) {
        this.dispenseUserId = dispenseUserId;
    }

    public String getDispenseUserName() {
        return dispenseUserName;
    }

    public void setDispenseUserName(String dispenseUserName) {
        this.dispenseUserName = dispenseUserName == null ? null : dispenseUserName.trim();
    }

    public Date getDispenseTime() {
        return dispenseTime;
    }

    public void setDispenseTime(Date dispenseTime) {
        this.dispenseTime = dispenseTime;
    }

    public Long getDeliveryUserId() {
        return deliveryUserId;
    }

    public void setDeliveryUserId(Long deliveryUserId) {
        this.deliveryUserId = deliveryUserId;
    }

    public String getDeliveryUserName() {
        return deliveryUserName;
    }

    public void setDeliveryUserName(String deliveryUserName) {
        this.deliveryUserName = deliveryUserName == null ? null : deliveryUserName.trim();
    }

    public Date getDeliveryTime() {
        return deliveryTime;
    }

    public void setDeliveryTime(Date deliveryTime) {
        this.deliveryTime = deliveryTime;
    }

    public String getRefuseReason() {
        return refuseReason;
    }

    public void setRefuseReason(String refuseReason) {
        this.refuseReason = refuseReason == null ? null : refuseReason.trim();
    }

    public Long getDispenseOrderId() {
        return dispenseOrderId;
    }

    public void setDispenseOrderId(Long dispenseOrderId) {
        this.dispenseOrderId = dispenseOrderId;
    }

    public Integer getSortNum() {
        return sortNum;
    }

    public void setSortNum(Integer sortNum) {
        this.sortNum = sortNum;
    }

    public Long getClinicId() {
        return clinicId;
    }

    public void setClinicId(Long clinicId) {
        this.clinicId = clinicId;
    }

    public String getIsEnabled() {
        return isEnabled;
    }

    public void setIsEnabled(String isEnabled) {
        this.isEnabled = isEnabled == null ? null : isEnabled.trim();
    }

    public String getIsDelete() {
        return isDelete;
    }

    public void setIsDelete(String isDelete) {
        this.isDelete = isDelete == null ? null : isDelete.trim();
    }

    public Long getCreateUserId() {
        return createUserId;
    }

    public void setCreateUserId(Long createUserId) {
        this.createUserId = createUserId;
    }

    public String getCreateBy() {
        return createBy;
    }

    public void setCreateBy(String createBy) {
        this.createBy = createBy == null ? null : createBy.trim();
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public Long getUpdateUserId() {
        return updateUserId;
    }

    public void setUpdateUserId(Long updateUserId) {
        this.updateUserId = updateUserId;
    }

    public String getUpdateBy() {
        return updateBy;
    }

    public void setUpdateBy(String updateBy) {
        this.updateBy = updateBy == null ? null : updateBy.trim();
    }

    public Date getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        OrderDelivery other = (OrderDelivery) that;
        return (this.getOrderId() == null ? other.getOrderId() == null : this.getOrderId().equals(other.getOrderId()))
            && (this.getVisitNo() == null ? other.getVisitNo() == null : this.getVisitNo().equals(other.getVisitNo()))
            && (this.getVisitDate() == null ? other.getVisitDate() == null : this.getVisitDate().equals(other.getVisitDate()))
            && (this.getOrderNo() == null ? other.getOrderNo() == null : this.getOrderNo().equals(other.getOrderNo()))
            && (this.getDeliveryStatus() == null ? other.getDeliveryStatus() == null : this.getDeliveryStatus().equals(other.getDeliveryStatus()))
            && (this.getTotalDeliveryQty() == null ? other.getTotalDeliveryQty() == null : this.getTotalDeliveryQty().equals(other.getTotalDeliveryQty()))
            && (this.getDoctorId() == null ? other.getDoctorId() == null : this.getDoctorId().equals(other.getDoctorId()))
            && (this.getDoctorName() == null ? other.getDoctorName() == null : this.getDoctorName().equals(other.getDoctorName()))
            && (this.getDeptId() == null ? other.getDeptId() == null : this.getDeptId().equals(other.getDeptId()))
            && (this.getDeptName() == null ? other.getDeptName() == null : this.getDeptName().equals(other.getDeptName()))
            && (this.getDiagnosis() == null ? other.getDiagnosis() == null : this.getDiagnosis().equals(other.getDiagnosis()))
            && (this.getDiagnosisTime() == null ? other.getDiagnosisTime() == null : this.getDiagnosisTime().equals(other.getDiagnosisTime()))
            && (this.getPatientId() == null ? other.getPatientId() == null : this.getPatientId().equals(other.getPatientId()))
            && (this.getPatientName() == null ? other.getPatientName() == null : this.getPatientName().equals(other.getPatientName()))
            && (this.getPatientGender() == null ? other.getPatientGender() == null : this.getPatientGender().equals(other.getPatientGender()))
            && (this.getPatientPhone() == null ? other.getPatientPhone() == null : this.getPatientPhone().equals(other.getPatientPhone()))
            && (this.getIdCard() == null ? other.getIdCard() == null : this.getIdCard().equals(other.getIdCard()))
            && (this.getAgeYear() == null ? other.getAgeYear() == null : this.getAgeYear().equals(other.getAgeYear()))
            && (this.getAgeMonth() == null ? other.getAgeMonth() == null : this.getAgeMonth().equals(other.getAgeMonth()))
            && (this.getSolarBirthday() == null ? other.getSolarBirthday() == null : this.getSolarBirthday().equals(other.getSolarBirthday()))
            && (this.getLunarBirthday() == null ? other.getLunarBirthday() == null : this.getLunarBirthday().equals(other.getLunarBirthday()))
            && (this.getWeight() == null ? other.getWeight() == null : this.getWeight().equals(other.getWeight()))
            && (this.getSystolicBp() == null ? other.getSystolicBp() == null : this.getSystolicBp().equals(other.getSystolicBp()))
            && (this.getDiastolicBp() == null ? other.getDiastolicBp() == null : this.getDiastolicBp().equals(other.getDiastolicBp()))
            && (this.getDispenseUserId() == null ? other.getDispenseUserId() == null : this.getDispenseUserId().equals(other.getDispenseUserId()))
            && (this.getDispenseUserName() == null ? other.getDispenseUserName() == null : this.getDispenseUserName().equals(other.getDispenseUserName()))
            && (this.getDispenseTime() == null ? other.getDispenseTime() == null : this.getDispenseTime().equals(other.getDispenseTime()))
            && (this.getDeliveryUserId() == null ? other.getDeliveryUserId() == null : this.getDeliveryUserId().equals(other.getDeliveryUserId()))
            && (this.getDeliveryUserName() == null ? other.getDeliveryUserName() == null : this.getDeliveryUserName().equals(other.getDeliveryUserName()))
            && (this.getDeliveryTime() == null ? other.getDeliveryTime() == null : this.getDeliveryTime().equals(other.getDeliveryTime()))
            && (this.getRefuseReason() == null ? other.getRefuseReason() == null : this.getRefuseReason().equals(other.getRefuseReason()))
            && (this.getDispenseOrderId() == null ? other.getDispenseOrderId() == null : this.getDispenseOrderId().equals(other.getDispenseOrderId()))
            && (this.getSortNum() == null ? other.getSortNum() == null : this.getSortNum().equals(other.getSortNum()))
            && (this.getClinicId() == null ? other.getClinicId() == null : this.getClinicId().equals(other.getClinicId()))
            && (this.getIsEnabled() == null ? other.getIsEnabled() == null : this.getIsEnabled().equals(other.getIsEnabled()))
            && (this.getIsDelete() == null ? other.getIsDelete() == null : this.getIsDelete().equals(other.getIsDelete()))
            && (this.getCreateUserId() == null ? other.getCreateUserId() == null : this.getCreateUserId().equals(other.getCreateUserId()))
            && (this.getCreateBy() == null ? other.getCreateBy() == null : this.getCreateBy().equals(other.getCreateBy()))
            && (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime()))
            && (this.getUpdateUserId() == null ? other.getUpdateUserId() == null : this.getUpdateUserId().equals(other.getUpdateUserId()))
            && (this.getUpdateBy() == null ? other.getUpdateBy() == null : this.getUpdateBy().equals(other.getUpdateBy()))
            && (this.getUpdateTime() == null ? other.getUpdateTime() == null : this.getUpdateTime().equals(other.getUpdateTime()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getOrderId() == null) ? 0 : getOrderId().hashCode());
        result = prime * result + ((getVisitNo() == null) ? 0 : getVisitNo().hashCode());
        result = prime * result + ((getVisitDate() == null) ? 0 : getVisitDate().hashCode());
        result = prime * result + ((getOrderNo() == null) ? 0 : getOrderNo().hashCode());
        result = prime * result + ((getDeliveryStatus() == null) ? 0 : getDeliveryStatus().hashCode());
        result = prime * result + ((getTotalDeliveryQty() == null) ? 0 : getTotalDeliveryQty().hashCode());
        result = prime * result + ((getDoctorId() == null) ? 0 : getDoctorId().hashCode());
        result = prime * result + ((getDoctorName() == null) ? 0 : getDoctorName().hashCode());
        result = prime * result + ((getDeptId() == null) ? 0 : getDeptId().hashCode());
        result = prime * result + ((getDeptName() == null) ? 0 : getDeptName().hashCode());
        result = prime * result + ((getDiagnosis() == null) ? 0 : getDiagnosis().hashCode());
        result = prime * result + ((getDiagnosisTime() == null) ? 0 : getDiagnosisTime().hashCode());
        result = prime * result + ((getPatientId() == null) ? 0 : getPatientId().hashCode());
        result = prime * result + ((getPatientName() == null) ? 0 : getPatientName().hashCode());
        result = prime * result + ((getPatientGender() == null) ? 0 : getPatientGender().hashCode());
        result = prime * result + ((getPatientPhone() == null) ? 0 : getPatientPhone().hashCode());
        result = prime * result + ((getIdCard() == null) ? 0 : getIdCard().hashCode());
        result = prime * result + ((getAgeYear() == null) ? 0 : getAgeYear().hashCode());
        result = prime * result + ((getAgeMonth() == null) ? 0 : getAgeMonth().hashCode());
        result = prime * result + ((getSolarBirthday() == null) ? 0 : getSolarBirthday().hashCode());
        result = prime * result + ((getLunarBirthday() == null) ? 0 : getLunarBirthday().hashCode());
        result = prime * result + ((getWeight() == null) ? 0 : getWeight().hashCode());
        result = prime * result + ((getSystolicBp() == null) ? 0 : getSystolicBp().hashCode());
        result = prime * result + ((getDiastolicBp() == null) ? 0 : getDiastolicBp().hashCode());
        result = prime * result + ((getDispenseUserId() == null) ? 0 : getDispenseUserId().hashCode());
        result = prime * result + ((getDispenseUserName() == null) ? 0 : getDispenseUserName().hashCode());
        result = prime * result + ((getDispenseTime() == null) ? 0 : getDispenseTime().hashCode());
        result = prime * result + ((getDeliveryUserId() == null) ? 0 : getDeliveryUserId().hashCode());
        result = prime * result + ((getDeliveryUserName() == null) ? 0 : getDeliveryUserName().hashCode());
        result = prime * result + ((getDeliveryTime() == null) ? 0 : getDeliveryTime().hashCode());
        result = prime * result + ((getRefuseReason() == null) ? 0 : getRefuseReason().hashCode());
        result = prime * result + ((getDispenseOrderId() == null) ? 0 : getDispenseOrderId().hashCode());
        result = prime * result + ((getSortNum() == null) ? 0 : getSortNum().hashCode());
        result = prime * result + ((getClinicId() == null) ? 0 : getClinicId().hashCode());
        result = prime * result + ((getIsEnabled() == null) ? 0 : getIsEnabled().hashCode());
        result = prime * result + ((getIsDelete() == null) ? 0 : getIsDelete().hashCode());
        result = prime * result + ((getCreateUserId() == null) ? 0 : getCreateUserId().hashCode());
        result = prime * result + ((getCreateBy() == null) ? 0 : getCreateBy().hashCode());
        result = prime * result + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode());
        result = prime * result + ((getUpdateUserId() == null) ? 0 : getUpdateUserId().hashCode());
        result = prime * result + ((getUpdateBy() == null) ? 0 : getUpdateBy().hashCode());
        result = prime * result + ((getUpdateTime() == null) ? 0 : getUpdateTime().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", orderId=").append(orderId);
        sb.append(", visitNo=").append(visitNo);
        sb.append(", visitDate=").append(visitDate);
        sb.append(", orderNo=").append(orderNo);
        sb.append(", deliveryStatus=").append(deliveryStatus);
        sb.append(", totalDeliveryQty=").append(totalDeliveryQty);
        sb.append(", doctorId=").append(doctorId);
        sb.append(", doctorName=").append(doctorName);
        sb.append(", deptId=").append(deptId);
        sb.append(", deptName=").append(deptName);
        sb.append(", diagnosis=").append(diagnosis);
        sb.append(", diagnosisTime=").append(diagnosisTime);
        sb.append(", patientId=").append(patientId);
        sb.append(", patientName=").append(patientName);
        sb.append(", patientGender=").append(patientGender);
        sb.append(", patientPhone=").append(patientPhone);
        sb.append(", idCard=").append(idCard);
        sb.append(", ageYear=").append(ageYear);
        sb.append(", ageMonth=").append(ageMonth);
        sb.append(", solarBirthday=").append(solarBirthday);
        sb.append(", lunarBirthday=").append(lunarBirthday);
        sb.append(", weight=").append(weight);
        sb.append(", systolicBp=").append(systolicBp);
        sb.append(", diastolicBp=").append(diastolicBp);
        sb.append(", dispenseUserId=").append(dispenseUserId);
        sb.append(", dispenseUserName=").append(dispenseUserName);
        sb.append(", dispenseTime=").append(dispenseTime);
        sb.append(", deliveryUserId=").append(deliveryUserId);
        sb.append(", deliveryUserName=").append(deliveryUserName);
        sb.append(", deliveryTime=").append(deliveryTime);
        sb.append(", refuseReason=").append(refuseReason);
        sb.append(", dispenseOrderId=").append(dispenseOrderId);
        sb.append(", sortNum=").append(sortNum);
        sb.append(", clinicId=").append(clinicId);
        sb.append(", isEnabled=").append(isEnabled);
        sb.append(", isDelete=").append(isDelete);
        sb.append(", createUserId=").append(createUserId);
        sb.append(", createBy=").append(createBy);
        sb.append(", createTime=").append(createTime);
        sb.append(", updateUserId=").append(updateUserId);
        sb.append(", updateBy=").append(updateBy);
        sb.append(", updateTime=").append(updateTime);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}